// eslint-disable-next-line import/no-extraneous-dependencies
import mockjs from 'mockjs';

export default {
  'POST /api/container/add': (req, res) => {
    res.send(
      mockjs.mock(
        {
          ret: 0,
          error: null
        }
      ),
    );
  },
  'POST /api/container/list': (req, res) => {
    res.send(
      mockjs.mock(
        {
          ret: 0,
          data: {
            list: [
              {
                id: 1,
                cntrName: "短吧勺",
                cntrMemo: "用于粉末状、凝胶状原料",
                cntrCreateTime: 1627376921,
                cntrUseTimes: 8,
                ifUsed: true
              },
              {
                id: 2,
                cntrName: "长吧勺",
                cntrMemo: "用于粉末状、凝胶状原料",
                cntrCreateTime: 1627376921,
                cntrUseTimes: 8,
                ifUsed: true
              },
              {
                id: 3,
                cntrName: "咖啡勺",
                cntrMemo: "用于粉末状、凝胶状原料",
                cntrCreateTime: 1627376921,
                cntrUseTimes: 8,
                ifUsed: false
              }
            ],
            total: 4,
            query: 4
          },
          error: null
        }
      ),
    );
  },
}
